import React from 'react';
import ReactDOM from 'react-dom';
import { createStore, applyMiddleware } from 'redux'
import { Provider } from 'react-redux'
import createLogger from 'redux-logger'
import thunk from 'redux-thunk'
import Route from './Config/Route';
import reducer from './Reducer'


import './css/bootstrap.min.css';
import './Stylesheets/wx/sm.min.css';
import "./Stylesheets/wx/scroll.css";
import './Stylesheets/wx/base.css';
import './Stylesheets/wx/common.css';
import './Stylesheets/wx/noticeCenter.css';
import './Stylesheets/wx/personalCenter.css';
import './Stylesheets/wx/personal.css';
import './Stylesheets/wx/recharge.css';
import './Stylesheets/wx/goodsDetails.css';
import './Stylesheets/wx/shipmentManage.css';
import './Stylesheets/wx/shoppingCarts.css';
import './Stylesheets/wx/index.css';



const middleware = [ thunk ]
if (process.env.NODE_ENV !== 'production') {
  middleware.push(createLogger())
}
const store = createStore(
  reducer,
  applyMiddleware(...middleware)
)
ReactDOM.render(
  <Provider store={store}>
    {Route}
  </Provider>,
  document.getElementById('root')
);
